package com.changgou.user.dao;

import com.changgou.user.pojo.User;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Update;
import tk.mybatis.mapper.common.Mapper;

/****
 * @Author:www.itheima.com
 * @Description:User的Dao
 * @Date www.itheima.com
 *****/
public interface UserMapper extends Mapper<User> {

    @Update("UPDATE tb_user SET points=points+#{points} WHERE username=#{username}")
    Integer addPoints(@Param("username") String username,@Param("points") int points);
}
